﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace BootstrapAdmin.DataAccess.Models;

/// <summary>
/// 点检信息
/// </summary>
[Table("ops_spot_check")]
public class SpotCheck
{
    [Key]
    public int Id { get; set; }

    /// <summary>
    /// 工站
    /// </summary>
    [NotNull]
    [Required]
    [Display(Name = "工站")]
    public string? Station { get; set; }

    /// <summary>
    /// 点检项
    /// </summary>
    [NotNull]
    [Required]
    [Display(Name = "点检项")]
    public string? Item { get; set; }

    /// <summary>
    /// 点检值
    /// </summary>
    [NotNull]
    [Required]
    [Display(Name = "点检值")]
    public string? Value { get; set; }

    /// <summary>
    /// 点检结果
    /// </summary>
    [Display(Name = "点检结果")]
    public bool IsPass { get; set; }

    /// <summary>
    /// 班次
    /// </summary>
    [Display(Name = "班次")]
    public string? Shift { get; set; }

    /// <summary>
    /// 记录时间
    /// </summary>
    [Display(Name = "记录时间")]
    public DateTime CreatedAt { get; set; }
}
